import * as THREE from 'three';

export class Helper {
  camera(camera) {
    const cameraHelper = new THREE.CameraHelper(camera);
    return cameraHelper;
  }

  grid() {
    const size = 20000;
    const divisions = 20;
    const gridHelper = new THREE.GridHelper(size, divisions);
    return gridHelper;
  }

  arrow() {
    const dir = new THREE.Vector3(0, 0, 0);
    //normalize the direction vector (convert to vector of length 1)
    dir.normalize();
    const origin = new THREE.Vector3(0, 0, 0);
    const length = 200;
    const color = 0xffff00;
    const arrowHelper = new THREE.ArrowHelper(dir, origin, length, color);
    return arrowHelper;
  }

  axes() {
    const axesHelper = new THREE.AxesHelper(500);
    return axesHelper;
  }
}
